Official flair site 您所在的位置:网站首页 flair 官网 Official flair site

Official flair site

2023-07-14 20:10| 来源: 网络整理| 查看: 265

Download Latest version 3.2-4.5 Warning: Based on python V3 Uploaded: Fri 26-May-2023 Fedora systems

The preferred way of installing flair is through the flair repository

Only once instructions Download the flair.repo and place it in the /etc/yum.repos.d/ directory $ sudo wget https://cern.ch/flair/download/fedora/flair.repo -O /etc/yum.repos.d/flair.repo Update the database $ sudo dnf update Install flair $ sudo dnf install flair The system updater will notify you for new versions. RPM based systems

For linux RPM based systems (Fedora, CentOS, SLC, Suse,...) flair-3.2-4.5.noarch.rpm flair-geoviewer-3.2-4.5.x86_64.rpm

Optionally you can download the source rpm packages and rebuild the rpm flair-3.2-4.5.src.rpm flair-geoviewer-3.2-4.5.src.rpm

UBUNTU systems

The preferred way of installing flair is through the flair repository

Only once instructions Install the public repository key $ wget -q -O - https://flair.web.cern.ch/flair/download/ubuntu/flair.gpg | sudo tee /etc/apt/trusted.gpg.d/flair.asc

Note: If you are getting WARNING messages from the apt command such as W: ... Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details. You need to remove the previous flair key with the command: sudo apt-key del "ADEE 61A6 5BAC D490 AE5A 9268 586B 734C 48EF 36D5" and re-install it with the above wget command

Install the repository. Currently it is provided for the latest latest 23.04 $ sudo add-apt-repository 'deb [arch=all,amd64] https://cern.ch/flair/download/ubuntu/23.04 /' 22.04 LTS $ sudo add-apt-repository 'deb [arch=all,amd64] https://cern.ch/flair/download/ubuntu/22.04 /' 20.04 LTS $ sudo add-apt-repository 'deb [arch=all,amd64] https://cern.ch/flair/download/ubuntu/20.04 /' 18.04 LTS $ sudo add-apt-repository 'deb [arch=all,amd64] https://cern.ch/flair/download/ubuntu/18.04 /' Type the command $ sudo apt install flair and flair together with all its dependencies will be installed (including flair-geoviewer, dicom etc...). The system updater will notify you for new versions. Update

To update the flair version either use the update-manager from ubuntu or from the command line

$ sudo apt update $ sudo apt upgrade DEB based systems

For linux DEBIAN based version (Ubuntu, Debian) Ubuntu 23.04 flair_3.2-4.5_ubuntu23.04_all.deb flair-geoviewer_3.2-4.5_ubuntu23.04_amd64.deb

Ubuntu 22.04 LTS flair_3.2-4.5_ubuntu22.04_all.deb flair-geoviewer_3.2-4.5_ubuntu22.04_amd64.deb

Ubuntu 20.04 LTS flair_3.2-4.5_ubuntu20.04_all.deb flair-geoviewer_3.2-4.5_ubuntu20.04_amd64.deb

Ubuntu 18.04 LTS flair_3.2-4.5_ubuntu18.04_all.deb flair-geoviewer_3.2-4.5_ubuntu18.04_amd64.deb

TAR source code

For MAC, linux and Windows

flair-3.2-4.5.tgz flair-geoviewer-3.2-4.5.tgz Auxiliary files DICOM

Dicom Hounsfield to materials transformation examples

dicom.tgz Extract in any folder preferably in the under the flair installation $ tar xzvf dicom.tgz Cluster Submission

Script as an example for cluster submission

qsubmit.sh Beta Versions

Beta / Unstable releases for testing can be found here.

Installation Instructions Requirements Flair is dependent on the following programs: Python interpreter version V3.6 or greater. Python usually comes pre-installed in most linux distributions, otherwise it can be downloaded from http://www.python.org

tkinter toolkit, this is the default graphical toolkit for python and usually it is shipped together with the interpreter. In Fedora distributions (Version>3) it has to be installed separately. In this case install it with the command (as superuser):

$ dnf -y install tkinter Tcl/Tk version V8.5 or greater. Optionally but strongly recommended flair-geoviewer a plugin to flair for interactive geometry editing, debugging and 3D visualization PIL (python imaging library) and the tk interface for image exporting from geoviewer. Typically on various distributions they appear with the name python-imaging and python-imaging-tk gnuplot version V4.0 or greater pydicom The python dicom library optionally if you want to convert DICOM files to FLUKA voxel numpy The python numeric library for dicom processing python3-gdcm for compressed DICOM images Source code compile requirements For compiling the source code you need the following development packages for your system C++ compiler preferably gnu g++ or clang++ GNU make python3-devel tk-devel and all its dependencies

RPM installation

Execute the following command as superuser:

$ rpm -ivh flair-X-XX.noarch.rpm

On distributions like Suse, Ubuntu etc. the package tkinter is called python-tk. Please verify that you have installed the required packages and then issue the command as superuser:

$ rpm -ivh --nodeps flair-X-XX.noarch.rpm Upgrade instructions

To upgrade to a new version when flair is already installed on your system:

$ rpm -Fvh flair-X.X-X.noarch.rpm

Or directly from the web site

$ rpm -Fvh http://flair.cern/flair/flair-X.X-X.noarch.rpm Built from src.rpm

Issue the command

$ rpmbuild --rebuild flair-geoviewer-X.X-X.src.rpm Install with window manager To install open with the file browser the download directory and double click, first on the "flair" and second on the "flair-geoviewer". WARNING: you need to have the "universe" software source enabled. To enable the "universe": Open the "Ubuntu Software Center" Menu -> Edit -> Software Sources Check the "Community-maintained free and open-source software (universe)" Close the Software center program In a terminal (e.g. xterm) type $ sudo apt update Then go to the download directory and double-click to install the Flair .deb package After the installation of Flair, double-click the flair-geoviewer .deb package, in order to install the Flair-Geoviewer

DEBIAN Install from command line

Manual installation can be done with the command:

$ dpkg -i flair_X.XX-X_all.deb flair-geoviewer_X.XX-XX_[amd64].deb TAR source code

Expand the archive to the appropriate directory use the following commands:

$ tar xzvf flair-X.XX.tgz

     or

$ gunzip -c flair-X.XX.tgz | tar xvf - Compile

To compile flair-geoviewer do the following:

$ tar xzvf flair-geoviewer-X-XX.tgz $ cd flair-geoviewer-X-XX $ make -j 8 $ make install install-bin install-mime $ make help will provide a help page with all available options Compile in parallel: -j 8 replace with the number of cores you have available

Requirements Flair is dependent on the following programs:

Xcode Command Line Tools It is a prerequisite for the installation of MacPorts (see next point). Install them with the command: $ xcode-select --install

MacPorts

The X11 Window System Via XQuartz (version greater than 2.8.1) or via MacPorts: $ sudo port install xorg-server xorg After then installation, please logout and login in order to use the MacPorts' X11 as the default server. * Please check the "Known warnings and errors" section below in case of a force stop of Flair while running Geoviewer.

GCC compiler version 8.5.0 or greater. ATTENTION: PLEASE DO NOT USE THE DEFAULT OSX GCC VERSION Instead of the default one, please install your own version using MacPorts: $ sudo port install gcc[version] and enable it with the command: $ sudo port select gcc mp-gcc[version] replacing [version] with the gcc version you want to install and use. For example gcc8, gcc9 or higher. For Catalina users, it is advised to use the gcc version 9.

Python interpreter version V3.6 or greater. ATTENTION: PLEASE DO NOT USE THE DEFAULT OSX PYTHON VERSION Instead of the default one, please install your own version using MacPorts: $ sudo port install python3[version] and enable it with the command: $ sudo port select --set python3 python3[version] replacing [version] with the python3 version you want to install and use. For example python37, python38

Tkinter toolkit, this is the default graphical toolkit for python and usually it is shipped together with the interpreter. For OsX operating systems it has to be installed separately. In this case install it with the command: sudo port install py3[version]-tkinter replacing [version] with the python3 version you installed above (i.e. py37, py38)

matplotlib A comprehensive library for creating static, animated, and interactive visualizations in Python. sudo port install py3[version]-matplotlib +tkinter replacing [version] with the python3 version you installed above (i.e. py37, py38)

pkg-config, a helper tool used when compiling applications and libraries sudo port install pkgconfig

Installation

For installing Flair, please expand from source and follow the instructions in the "Configuring the environment" section below for being able to run the program. For installing Geoviewer, please expand and compile from source following the instructions in the "Compile from source" section below.

Configuring the environment

For configuring the environment and being able to run Flair through the command line, add the following line in the ~/.profile (or ~/.bash_profile):  alias flair='PATH_FLAIR/flair' and replace PATH_FLAIR with the directory path where Flair was expanded. Then, to run Flair, open a new terminal session and type:  $ flair

Since the commands for setting the environment differ for different shells, please adapt the above line for non-bash shells.

Optionally, but strongly recommended:

* In the commands below replace [version] with the python3 version you installed above (i.e. py37, py38)

flair-geoviewer a plugin to flair for interactive geometry editing, debugging and 3D visualization

PIL (python imaging library) and the tk interface for image exporting from geoviewer. $ sudo port install py3[version]-Pillow

gnuplot version V4.0 or greater $ sudo port install gnuplot

numpy The python numeric library for dicom processing $ sudo port install py3[version]-numpy

scipy A Python-based ecosystem of open-source software for mathematics, science, and engineering sudo port install py3[version]-scipy

pydicom The python dicom library optionally if you want to convert DICOM files to FLUKA voxel $ sudo port install py3[version]-pydicom $ sudo port install py3[version]-Pillow

In case Flair still requests for the DICOM package, please do: $ sudo port install py3[version]-pip $ sudo pip-3.7 install pillow

Ghostscript an interpreter for the PostScript language and for PDF $ sudo port install ghostscript

GDB the GNU Project debugger $ sudo port install gdb

XTerm the standard terminal emulator for the X Window System $ sudo port install xterm

Known warnings and errors

For macOS Mojave users: If the build process of Geoviewer fails with an error indicating that C++ headers are still missing, the installed Xcode version is still lacking appropriate header files. For installing them, please run: $ sudo installer -pkg /Library/Developer/CommandLineTools/Packages/macOS_SDK_headers_for_macOS_10.14.pkg -target /

If the build process of Geoviewer fails with an error: "fatal error: X11/Xlib.h: No such file or directory, please re-install the XQuartz package or, better, use the X11 window system provided by MacPorts as advised above.

If the "Dicom" tab is not working leading to an error: "Error: cannot import name '_tkagg' from 'matplotlib.backends'", please re-install matplotlib with the +tkinter variant, as described in the instructions above.

In case of a force stop leading to an error similar to: "Assertion failed: (pthreadret == 0), function _xcb_in_wake_up_next_reader, file xcb_in.c, line 926." or: "line 15: 1120 Segmentation fault: 11 CMD @" , please downgrade the xorg-libxcb and xorg-xcb-proto from verion 1.14 to 1.13, following the instructions described here. Please note that this malfunction is due to the fact that two different versions of the libxcb library are loaded:  - the first one is loaded from XQuartz that contains the version 1.12  - the second one from the dependencies of py38-tkinter installed via MacPorts and that is the most recent version 1.14. Thus, verify that the XQuartz version is 2.8.1 or use of the X11 window system provided by MacPorts, as described above.

Compile

To compile flair-geoviewer do the following:

$ tar xzvf flair-geoviewer-X-XX.tgz $ cd flair-geoviewer-X-XX $ make -j 8 $ make install DESTDIR=PATH_FLAIR and replace PATH_FLAIR with the directory path where Flair was expanded.

Compile in parallel: -j 8 replace with the number of cores you have available

Android Phones or Tables

Flair v3 can run as well on android phone from v7+ and/or tablets.

Requirements

Install the termux application on android. Termux is an android terminal emulator and a linux environment application

Once termux is installed launch the application and install in the terminal the following packages for flair

$ pkg install x11-repo $ pkg install python python-tkinter gnuplot make clang xorgproto

for the x11 environment you can follow the guide Graphical Environment

flair

Download the source packages of flair and geoviewer as described in the section above, and compile the geoviewer

Running

To run flair on android you need to

Start vncviewer Start termux In the terminal type $ DISPLAY=:1 python flair.py Switch to the vncviewer and you should have flair running on your phone


【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有